﻿<%@ Page Language="C#" AutoEventWireup="true"  CodeFile="Default.aspx.cs" Inherits="_Default" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
<head id="Head1" runat="server">
    <title>Untitled Page</title>
</head>
<body>
    <form id="form1" runat="server">
    <div>
		 <asp:LinqDataSource ID="LinqDataSource1" runat="server" 
			 ContextTypeName="AdventureWorksDataContext" EnableDelete="True" 
			 EnableInsert="True" EnableUpdate="True" TableName="Products">
		 </asp:LinqDataSource>
		 <asp:GridView ID="GridView1" runat="server" AutoGenerateColumns="False" 
			 DataKeyNames="ProductID" DataSourceID="LinqDataSource1" AllowPaging="True" 
			 AllowSorting="True">
			 <Columns>
				 <asp:CommandField ShowDeleteButton="True" ShowEditButton="True" />
				 <asp:BoundField DataField="ProductID" HeaderText="ProductID" 
					 InsertVisible="False" ReadOnly="True" SortExpression="ProductID" />
				 <asp:BoundField DataField="Name" HeaderText="Name" SortExpression="Name" />
				 <asp:BoundField DataField="ProductNumber" HeaderText="ProductNumber" 
					 SortExpression="ProductNumber" />
				 <asp:CheckBoxField DataField="MakeFlag" HeaderText="MakeFlag" 
					 SortExpression="MakeFlag" />
				 <asp:BoundField DataField="SafetyStockLevel" HeaderText="SafetyStockLevel" 
					 SortExpression="SafetyStockLevel" />
				 <asp:BoundField DataField="ReorderPoint" HeaderText="ReorderPoint" 
					 SortExpression="ReorderPoint" />
			 </Columns>
		 </asp:GridView>
    </div>
    </form>
</body>
</html>
